1. Field of the Invention
The present invention relates generally to storage systems.
2. Description of Related Art
To reduce the waste of physical blocks in storage volumes, storage systems have been developed that utilize dynamic chunk allocation (DCA) capability (also referred to as “dynamic capacity allocation” or “thin provisioning storage systems”). Under DCA technology, a logical volume is allocated for use by one or more host computers for storing data, but no physical blocks of storage are initially allocated to the volume. Instead, when the storage system receives a write command from a host directed to an area of the volume that has not yet had physical storage capacity allocated to it, the storage system allocates an area of physical storage space (commonly referred to as a storage “chunk”) from a pool of available physical storage areas (i.e., a storage chunk pool). The chunk of storage capacity is a physical storage area composed of one or more physical blocks of storage space on one or more storage devices, such as hard disk drives. When an allocated physical storage area already exists for a portion of a thin-provisioned volume, this indicates that data has already been written to that portion of the volume by a host computer at least one time. In some embodiments, a thin-provisioned volume might also be considered a type of a virtual volume in its initial state, since a large volume capacity is presented to the user, but actual physical storage space has not yet been allocated for this volume.
DCA storage is able to reduce waste of physical blocks in a storage system because the physical blocks are only allocated when writing of data actually takes place. If the storage system receives no write command to certain ranges or segments of the thin provisioned volume, then physical data blocks are not actually allocated to those portions of the volume. This is different from conventional storage systems in which a volume is allocated as having a certain amount of physical storage space when the volume is created. Thus, conventional storage systems that do not incorporate dynamic capacity allocation capability usually have large amounts of unused physical data blocks (i.e., wasted physical blocks) allocated to volumes in the system even though no data is stored in those blocks.
US Patent Application Publication 20040162958, to Yoshiki Kano et al., entitled “Automated On-Line Expansion Method for Storage Device”, filed Feb. 23, 2004, the disclosure of which is incorporated herein by reference, discloses such a storage system that includes automated on-line capacity expansion capability that dynamically allocates storage chunks to a volume as areas of the volume receive write commands. However, this prior art does not disclose any backup or restore methods for use in protecting data in such thin-provisioned volumes in DCA storage systems. Therefore, as is described in more detail below, waste storage chunks may be allocated in the storage system when a backup image is used to restore data to the storage system.
As is well known, periodic backup of stored data is necessary for protecting the data in case of disk failure, catastrophe, or the like. When data is lost or erased, or when a storage device fails, the missing data is typically recovered by restoring data from a backup image created at some earlier point in time. Typically, when performing a volume-level backup, a backup computer reads data from the volume being backed up, and writes the data to a tape or other backup medium. During the backup process, the backup computer reads the volume from the beginning to the end, while writing the data thus read to the backup medium. However, when this conventional backup technique is applied to a volume on a storage system that utilizes DCA capability, the backup program attempts to read data from areas (segments) of the volume that have not yet had physical storage space allocated to them. In response, the storage system typically responds with a default void data pattern when the backup computer attempts to read data on each segment of the volume that has not yet had physical storage space allocated to it. In a case where the thin provisioned volume is quite large, and has used only a small percentage of the capacity allocated to physical storage areas, a large amount of the backed up data can be this default data pattern. Consequently, on the backup image of the volume, a large amount of the backed-up data might be wasted space because normally whole volume images are stored during data backup using conventional backup software.
Furthermore, when this backed-up volume image is used in a volume-level restore operation, the backup computer reads data from the backup medium and writes the data to the restored volume in the DCA storage system. The backup computer conventionally restores a volume by writing the volume from beginning to end. Thus, the whole backup image is used to rebuild the volume, which defeats the purpose of dynamic chunk allocation capability because the backup computer issues write commands to all the allocated address blocks in the volume, thereby allocating blocks to the volume even though they are filled with null data of the default data pattern, which can result in unnecessary wasting of large amounts of physical storage space.